---
apiVersion: "v1"
kind: "List"
items:
{% for claim in persistent_volume_claims %}
- apiVersion: "v1"
  kind: "PersistentVolumeClaim"
  metadata:
    name: "{{ claim.name }}"
{% if claim.annotations %}
    annotations:
{% for annotation in claim.annotations %}
        {{ annotation }}
{% endfor %}
{% endif %}
  spec:
    accessModes: {{ claim.access_modes | lib_utils_to_padded_yaml(2, 2) }}
    resources:
      requests:
        storage: "{{ claim.capacity }}"
{% if claim.storageclass|length > 0 %}
    storageClassName: "{{ claim.storageclass }}"
{% endif %}
{% endfor %}
